package com.topfinance.payment.dto;

import java.io.Serializable;

import com.topfinance.frame.util.StringUtil;

public class TC2BisClasMsgDto implements Serializable {
	private static final String MSGTag = "业务报文";
	private String tp_code;
	private String clas_code;
	private String clas_name;
	private String msg_code;
	private String msg_name;
	private String app_type;
	
	public TC2BisClasMsgDto(String tp_code, String clas_code, String clas_name, String msg_code, String msg_name,
			String app_type) {
		super();
		this.tp_code = tp_code;
		this.clas_code = clas_code;
		this.clas_name = clas_name;
		this.msg_code = msg_code;
		this.msg_name = msg_name;
		this.app_type = app_type;
	}
	public TC2BisClasMsgDto(String tp_code, String clas_code, String clas_name, String msg_code, String msg_name) {
		super();
		this.tp_code = tp_code;
		this.clas_code = clas_code;
		this.clas_name = clas_name;
		this.msg_code = msg_code;
		this.msg_name = msg_name;
	}
	public String getTpCode() {
		return tp_code;
	}
	public void setTpCode(String tp_code) {
		this.tp_code = tp_code;
	}
	public String getClasCode() {
		return clas_code;
	}
	public void setClasCode(String clas_code) {
		this.clas_code = clas_code;
	}
	public String getClasMsgName() {
		if(StringUtil.isNotNullStr(msg_name)){
			int index = msg_name.indexOf(MSGTag);
			if(index>0)
				return clas_name + "-" + msg_name.substring(0,index); 
		}
		return clas_name;
	}
	public String getClasName() {
		return clas_name;
	}
	public void setClasName(String clas_name) {
		this.clas_name = clas_name;
	}
	public String getMsgCode() {
		return msg_code;
	}
	public void setMsgCode(String msg_code) {
		this.msg_code = msg_code;
	}
	public String getMsgName() {
		return msg_name;
	}
	public void setMsgName(String msg_name) {
		this.msg_name = msg_name;
	}
	public String getAppType() {
		return app_type;
	}
	public void setAppType(String app_type) {
		this.app_type = app_type;
	}
	
}
